import requests
import json

youdao_translate_url = "https://dict.youdao.com/keyword/key"
youdao_translat_data = {"text": "字典"}
youdao_translat_headers = {
    "User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/110.0.0.0 Safari/537.36 Edg/110.0.1587.63"}

result = requests.post(youdao_translate_url,youdao_translat_data,youdao_translat_headers)
res = result.content.decode()

print(json.loads(res))